def any(itr):
    for i in itr:
        if i:
            return True
    return False

def all(itr):
    for i in itr:
        if not i:
            return False
    return True
